package com.gimi.test_jpa.com.gimi.schedule;

import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

@Component
public class ScheduledTask {

//    @Scheduled(fixedDelay = 5000) //开启注解即可执行定时任务
    public void task1(){
        System.out.println("定时任务执行--------"+Thread.currentThread().getName());
    }
}
